<!DOCTYPE html>
<html lang="zh-CN">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <script>
      // 普通类型
      let aa = 11
      let bb = aa
      bb = 22
      console.log(aa) // 11
      console.log(bb) // 22
      

      // 引用类型
      let obj = {
        aa: 33,
      }
      // 这里的赋值是内存地址赋值，其实大家都是引用同一个对象
      let obj2 = obj

      obj2.aa = 44

      console.log(obj2.aa)  // 44
      console.log(obj.aa)   // 44
    </script>
  </body>
</html>
